package com.study.model;

import java.util.Set;

public class Teacher {
    private Integer id;
    private String  name;
    private Set<Student> students;

    public Teacher() {
    }

    public Teacher(Integer id, String name, Set<Student> students) {
        this.id = id;
        this.name = name;
        this.students = students;
    }

    /**
     * 获取
     * @return id
     */
    public Integer getId() {
        return id;
    }

    /**
     * 设置
     * @param id
     */
    public void setId(Integer id) {
        this.id = id;
    }

    /**
     * 获取
     * @return name
     */
    public String getName() {
        return name;
    }

    /**
     * 设置
     * @param name
     */
    public void setName(String name) {
        this.name = name;
    }

    /**
     * 获取
     * @return students
     */
    public Set<Student> getStudents() {
        return students;
    }

    /**
     * 设置
     * @param students
     */
    public void setStudents(Set<Student> students) {
        this.students = students;
    }

    public String toString() {
        return "Teacher{id = " + id + ", name = " + name + ", students = " + students + "}";
    }
}
